import { createRouter, createWebHashHistory } from 'vue-router'
import page2Vue from '../views/demo/page2.vue'
import index from '../views/layout/index/index.vue'

const routes = [ 
  {
    path:  '/',
    component: index
   },
  {
   path:  '/page2',
   component: page2Vue
  }
]

// 导出路由
const router = createRouter({
    history: createWebHashHistory (),
    routes
});

export default router;